package com.example.test.advice.第五章_数组和集合.建议62_警惕数组的浅拷贝;

import org.apache.commons.lang3.builder.ToStringBuilder;

/**
 * 气球
 */
public class Ballon {

    //编号
    private int id;
    //颜色
    private Color color;

    public Ballon(int id, Color color) {
        this.id = id;
        this.color = color;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public Color getColor() {
        return color;
    }

    public void setColor(Color color) {
        this.color = color;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this)
                .append("编号",id)
                .append("颜色",color)
                .toString();
    }
}
